package exam.dao;

import org.apache.ibatis.annotations.Param;
import org.example.domain.Student;

import java.util.List;
import java.util.Map;

public interface StudentDao {
    Student selectStudentByMnemonic_code(String mnemonic);
    void save(Student student);
    List<Student> query(Map<String,Object> map);
    List<Student> queryClassStudent(Map<String,String> map);
    void addOneStudent(Student student);
    Student editStudent(String code);
    void editSave(Student student);

    /**
     *
     * @param map 包含 grade major class_no
     */
    void deleteClass(Map<String,String> map);
    void deleteClassStudent(Map<String,String> studentInfo);
    String selectStudentAllCode(@Param("classInfo") String classInfo,@Param("excludeStudentCode") String excludeStudentCode);
    int selectClassStudentTotalNumber(String classInfo);
    List<Student> selectStudentByNameAndCode(List<String> studentsInfo);
    int judgeClassExist(String classInfo);
    List<Student> selectStudentByClassInfo(String classInfo);
    List<Student> selectStudentByCodes(List<String> codes);
    List<Student> selectNoneExistStudentByCodes(@Param("className")String className,@Param("codes") List<String> codes);
    String selectClassAllStudentCode(String classInfo);
    String selectClassAllStudentId(String classInfo);
    String selectClassIdsByCodes(List<String> codes);
    List<Student> selectStudentByIds(List<Long> ids);
}
